home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-01
/
wtek0693.zip
/
OOPALLEY.ZIP
/
README.TXT
< prev
next >
Wrap
Text File
|
1993-04-29
|
4KB
|
120 lines
4/29/93
Windows Tech Journal
OOP Alley, June 1993
A Sure Cure for YALL
Greg Voss
Introduction to Collections in C++
o Source code for DiskTutor/NIH
collection class library
o Example programs from June Listings
o Verification suite
Usage Notes
===========
Recommended root directory: c:\dt
Use pkunzip with -d option
Compiled with BC++ 3.1
This is a quick and dirty distribution of
the collection class library discussed in
the June '93 column. This library
is basically Keith Gorlen's original
NIH class library scaled down to fit
comfortably within a DOS small memory
model. It has also been simplified with
an eye toward teaching collection classes
rather than taking the everthing-but-the-
kitchen-sink approach.
The original version of the DiskTutor class library
was compiled with Turbo C++ 2.0 in June of 1990
and was distributed with Turbo C++ DiskTutor--
a book that came packaged with a streamlined version
of Borland's C++ compiler. Revisions were made to
make the code compatible with the more strict error
checking implemented by BC++ 3.1. Large model
compilation has not been tested since June 1990.
There are some tricky issues for large model
compilation dealing with pointers
(see dtlib\oopsconf.h).
The header files are pretty clean, but some of the
source files are pretty ugly. That will be fixed
shortly. Next month's OOP Alley also uses the
same class library and by then it will be cleaned
up and modified to compile with MSC 7.0.
The current version compiles without generating
warning messages or errors. There are three
basic directories you need to deal with:
dt\dtlib library source
dt\june93 OOP Alley Listings for June '93
dt\dtlibv verification suite
You don't need to work with the verification
directory. It's just there to be sure that the
library has been properly compiled and installed.
Building the Library
====================
1. Change to library directory
>cd dtlib
2. Compile
>make
3. Install
>make install
The last step will copy the header files to
../include and copy dt.lib (created in step 2
above) to ../lib
Compiling Examples
==================
1. Change to example directory
>cd june93
2. Compile examples
>make
Notes on Verification Suite
===========================
The programs in dtlibv automate verification of the library.
Only a fraction of the methods are actually tested, but
you can get an idea if something is grossly wrong with
the library by running the verification suite.
Unfortunately most DOS users will not be able to run
the automated suite (though you can run any of the
test files manually). This is because some UNIX pipes
and filters are required to completely automate the
testing. Namely you need a version of diff that
accepts a '-' as its first argument, indicating that
the standard input piped to diff is to be used
in place of the file normally specified by the
first argument. I'm working on making the test
suite run automatically under DOS. I have public
domain source for diff.c which is 90% of the battle.
The rest involves minor modification of the
makefile. Even if you don't have a UNIX shell,
you can compile the test suite programs and get
a sense how the automated suite works by looking
at the 'verify' target in the makefile.
Hopefully the automated DOS versionn of the test
suite will be distributed with OOP Alley code for
July.
Happy OOPing -gmv